<template>
	<div>
		<Card style="margin-bottom: 10px;">
			<Tabs value="data20000000">
				<TabPane :label="$t('newsInfoManager.data20000000')" name="data20000000">
					<div class="message-page-con message-category-con" style="width: 0px;">
					</div>
					<div style="left: 0px;" class="message-page-con message-view-con" v-for="item in languageTypeList" :key="item.index" v-show="item.index == currentTypeTwo">
					  <dataPane modId="20000000" :localeName="item.index"></dataPane>
					</div>
				</TabPane>
        <TabPane label="轮播图管理" name="data20001000">
        	<div class="message-page-con message-category-con" style="width: 0px;">
        	</div>
        	<div style="left: 0px;" class="message-page-con message-view-con" v-for="item in languageTypeList" :key="item.index" v-show="item.index == currentTypeTwo">
        	  <dataPane modId="20001000" :localeName="item.index"></dataPane>
        	</div>
        </TabPane>
			</Tabs>
      <!-- <Tabs value="data20001000">
      	<TabPane label="轮播图管理" name="data20001000">
      		<div class="message-page-con message-category-con" style="width: 0px;">
      		</div>
      		<div style="left: 0px;" class="message-page-con message-view-con" v-for="item in languageTypeList" :key="item.index" v-show="item.index == currentTypeTwo">
      		  <dataPane modId="20001000" :localeName="item.index"></dataPane>
      		</div>
      	</TabPane>
      </Tabs> -->
		</Card>
	</div>

</template>

<script>
	import {getLanguageTypeList} from '@/api/emums';
	import dataPane from './components/data-pane'
	export default {
		components: {
		  dataPane
		},
		data() {
			return {
				languageTypeList: [],
				currentTypeTwo:''
			};
		},
		mounted: function() {
			this.getLanguageTypeList();
		},
		computed: {
		},
		methods: {
			getLanguageTypeList() {
				getLanguageTypeList().then(response => {
					const data = response.data;
					this.languageTypeList = data.data;
					this.currentTypeTwo = this.languageTypeList[0].index;
					this.$nextTick(()=>{
						this.$refs.two.updateActiveName();
					})
				}).catch(error => {

				});
			},
			handleSelectTwo(index){
				this.currentTypeTwo = index
			}
		}
	};
</script>
<style lang="less">
.ivu-tabs-tabpane{
	position: relative;
}
</style>
